/**
 * Promise.withResolvers
 * @return array [promise,resolve,reject]
 */
$.when = function(){
	let B = (Y,N)=>{ done=Y; fail=N };
	let done, fail, pm=new Promise(B);
	return [pm, done, fail];
};
